<template>
	<view class="disposal">
		<view class="disposal_content">
			<view class="disposal_content_wait"></view>
			<view class="disposal_content_text">
				<view class="disposal_content_text_title">
					待处置
				</view>
				<view class="disposal_content_text_value">
					{{pending}}
					<span class="disposal_content_text_unit">件</span>
				</view>
			</view>
		</view>
		<view class="disposal_content">
			<view class="disposal_content_finish"></view>
			<view class="disposal_content_text">
				<view class="disposal_content_text_title">
					已处置
				</view>
				<view class="disposal_content_text_value">
					{{disposed}}
					<span class="disposal_content_text_unit">件</span>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	import {
		getDisposalStatus
	} from '@/common/api/approve/home/home_api.js'
	import {
		mapGetters
	} from 'vuex';
	export default {
		data() {
			return {
				pending: '',
				disposed: ''
			}
		},
		computed: {
			...mapGetters(['APPROVE_DEPT', 'getParentid'])
		},
		mounted() {
			this.getDisposalStatusList()
		},
		methods: {
			async getDisposalStatusList() {
				console.log(this.getParentid, '55555');
				const res = await getDisposalStatus(this.getParentid)
				this.pending = res.data.pending
				this.disposed = res.data.disposed
			}
		}
	}
</script>

<style lang="scss" scoped>
	.disposal {
		height: 100%;
		width: 100%;
		display: flex;
		flex-direction: row;
		align-items: center;
		justify-content: center;

		.disposal_content {
			width: 50%;
			height: 100%;
			display: flex;
			flex-direction: row;
			align-items: center;
			justify-content: center;
			margin-top: 2%;

			.disposal_content_wait {
				width: 50%;
				height: 100%;
				background-image: url('../../static/images/home/组 6.png');
				background-size: 30%;
				background-position: 88% center;
				background-repeat: no-repeat;
				margin-left: 5%;
			}

			.disposal_content_finish {
				width: 50%;
				height: 100%;
				background-image: url('../../static/images/home/组 6 (1).png');
				background-size: 30%;
				background-position: 88% center;
				background-repeat: no-repeat;
				margin-left: -25%;
			}

			.disposal_content_text {
				width: 50%;
				height: 100%;
				display: flex;
				flex-direction: column;
				align-items: left;
				justify-content: center;

				.disposal_content_text_title {
					font-family: PingFang SC;
					font-weight: 500;
					font-size: 24rpx;
					color: #bdbdbd;
					line-height: 32rpx;
				}

				.disposal_content_text_value {
					font-family: Myriad Pro;
					font-weight: 600;
					font-size: 32rpx;
					color: #1F1F1F;
				}

				.disposal_content_text_unit {
					font-family: PingFang SC;
					font-weight: 600;
					font-size: 24rpx;
					color: #bdbdbd;
					padding-left: 5%;
				}
			}
		}
	}
</style>